import request from '@/utils/request'

export function fetchList(query) {
  return request({
    url: '/mechanism/quarters/getList',
    method: 'post',
    data: query
  })
}
export function fetchQartersAvailable(query) {
  return request({
    url: '/mechanism/quarters/getAvailable',
    method: 'post',
    data: query
  })
}

export function fetchArticle(id) {
  return request({
    url: '/mechanism/quarters/getDetail',
    method: 'post',
    data: { id }
  })
}

export function saveQuarters(id) {
  return request({
    url: '/mechanism/quarters/save',
    method: 'post',
    data: id
  })
}

export function removeQuartersByID(id) {
  return request({
    url: '/mechanism/quarters/delete',
    method: 'post',
    data: id
  })
}

export function changeQuartersStatusByID(formdata) {
  return request({
    url: '/mechanism/quarters/change-status',
    method: 'post',
    data: formdata
  })
}

